package com.jdrx.sw.sewage.beans.vo;

import com.jdrx.sw.sewage.beans.vo.base.PageVO;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

@Data
@EqualsAndHashCode(callSuper = true)
public class DeviceTimeDataPageVO<T> extends PageVO<T> implements Serializable {

    private Map<String,Object> title;

    public static <V> DeviceTimeDataPageVO<V> toPageVO(List<V> list) {
        PageVO<V> pageVo = PageVO.toPageVO(list);
        DeviceTimeDataPageVO<V> infoPageVO = new DeviceTimeDataPageVO<>();
        infoPageVO.copyPageInfo(pageVo);
        infoPageVO.setData(list);
        return infoPageVO;
    }
}
